import { hasPermi  } from '@/utils/mUtils'
export const vHasPermi = {
  mounted(el, binding, vnode) {
    const { value } = binding
    if (value && value instanceof Array && value.length > 0) {
      const hasPermissions = hasPermi(value)
      if (!hasPermissions) {
        el.parentNode && el.parentNode.removeChild(el)
      }
    } else {
    }
  }
}
